package com.pshcp.mapper;

import com.pshcp.common.config.MyMapper;
import com.pshcp.domain.model.News;
import org.apache.ibatis.annotations.Param;

import java.time.LocalDate;
import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author auto generator
 * @since 2022-11-24
 */
public interface NewsMapper extends MyMapper<News> {

    /**
     * 批量插入
     * @param list
     * @return
     */
    int batchInsert(List<News> list);

    /**
     * 根据日期删除新闻
     * ge表示 >=
     * @param day 含当前日期
     * @return
     */
    int delByGeDay(@Param("day") LocalDate day, @Param("type") Integer type);

}
